settings.outformat = "pdf";
size(3cm, 0);
draw((3, 0)--(0, 0)--(3, 4));
real linewidth = linewidth(currentpen);

/* 使用 margin=ArrowMargins 绘制的路径,
在末尾缩短 0.5 linewidth, 在开头缩短 full linewidth. */

margin ArrowMargins = TrueMargin(linewidth, 0.5 linewidth);
draw(arc((0, 0), (2, 0), (3, 4)), arrow = Arrow(TeXHead), red,
     margin = ArrowMargins);
draw(arc((0, 0), (2, 0), (3, 4), direction = CW), arrow = Arrow(TeXHead), blue,
     margin = ArrowMargins);